import request from '@/utils/request'

// 查询抽奖号码列表
export function listLottery(query) {
  return request({
    url: '/system/lottery/list',
    method: 'get',
    params: query
  })
}

// 查询抽奖号码详细
export function getLottery(lotteryId) {
  return request({
    url: '/system/lottery/' + lotteryId,
    method: 'get'
  })
}

// 新增抽奖号码
export function addLottery(data) {
  return request({
    url: '/system/lottery',
    method: 'post',
    data: data
  })
}

// 修改抽奖号码
export function updateLottery(data) {
  return request({
    url: '/system/lottery',
    method: 'put',
    data: data
  })
}

// 删除抽奖号码
export function delLottery(lotteryId) {
  return request({
    url: '/system/lottery/' + lotteryId,
    method: 'delete'
  })
}
